package spring.ai_chat.ollama.chatApi.pojo;

import lombok.Data;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;

@Data
public class ModuleReq {
//    private String model = "phi3.5:3.8b";
//    private String model = "llama3.2:1b";
//    private String model = "deepseek-r1:14b";
    private String model = "llama3.1:8b";


    private boolean stream = false;
//    private double temperature = 0.7;  // 调整为0.7，减少随机性
//    private double top_p = 0.9;
//    private Integer max_length = 2048;  // 增加到2048支持更长对话
//    private double repetition_penalty = 1.1;  // 微调重复惩罚
//    private String[] stop = {"\n\n", "###"};  // 改为数组

    private double temperature = 0.7;    // 稍低温度保持稳定风格
    private double top_p = 0.85;
    private Integer max_length = 60;     // 大幅缩短，控制在1-2句话
    private double repetition_penalty = 1.1;
    private String[] stop = {"\n", "用户："};



    // 使用消息列表替代单独的prompt
    private List<ChatMessage> messages;

    public ModuleReq(List<ChatMessage> messages) {
        this.messages = messages;
    }
}
